﻿package fr.babos.test.data
{
	import fr.babos.core.data.collect.DataCollection;
	import fr.babos.core.data.items.IDataItem;
	import fr.babos.core.roles.IIdentifiable;
	
	/**
	 * @author ZoulouX
	 */
	public class BabosDataTestItem2 implements IDataItem, IIdentifiable
	{
		/**
		 * L'id de l'item
		 */
		protected var _id					:uint;
		
		/**
		 * L'id de l'item
		 */
		public function get id ():uint { return _id; }
		public function set id (value:uint):void 
		{
			_id = value;
		}
		
		/**
		 * La date de l'item
		 */
		public var date						:Date						= new Date(0);
		
		/**
		 * La collection de babos
		 */
		public var babosCollections			:DataCollection				= new DataCollection(BabosDataTestItem2);
		
		/**
		 * Le constructeur
		 */
		public function BabosDataTestItem2 ()
		{
			
		}
		
		/**
		 * Afficher
		 * @return
		 */
		public function toString ():String
		{
			return "BabosDataTestItem2 {id: " + id + ", date: " + date.getDate() + "-" + (date.getMonth() + 1) + "-" + date.getFullYear() + ", collection: " + babosCollections.length + "}";
		}
	}
}